package com.atguigu.contacts;

import java.util.Iterator;

public class ArrayTest {
	public static void main(String[] args) {
		int[] ids;
		ids = new int[] { 11, 2, 3, 4 }; // 静态初始化
		String[] names = new String[5]; // 动态初始化
		names[0] = "张三";
		names[1] = "张三2";
		names[2] = "张三3";
		names[3] = "张三4";
		names[4] = "张三5";
		for (int i = 0; i < names.length; i++) {
			System.out.println("数组2-" + names[i]);
		}
		/*
		 * System.out.println("数组1-"+ ids[0]); System.out.println("数组2-"+
		 * names[0]);
		 */
	}
}
